Software Development
Working with Spring Data JPA
Working with Spring Data JPA: Custom Queries
Working with Spring Data JPA: Derived Query Methods
Working with Spring Data JPA: The Fundamentals of Spring Data JPA

Working with Spring Data JPA: Custom Queries

Course Number:
it_jpdjpadj_03_enus
Lesson Objectives

Working with Spring Data JPA: Custom Queries

  • discover the key concepts covered in this course
  • apply the @Query annotation to map queries to be run against a database to a method in a CrudRepository
  • define custom queries that bind to parameters passed to a CrudRepository method
  • configure update and delete operations in a CrudRepository
  • define custom queries that can be referenced by names in a CrudRepository
  • define named queries in an XML file and a Java source file
  • summarize the key concepts covered in this course

Overview/Description
Through this course, explore how to map your own SQL queries to methods in a CrudRepository and leave the implementation of running the queries and processing the results to the Spring Framework. You'll investigate the use of @Query annotation to map simple select queries to methods in a CrudRepository and learn how the rest of the workaround connections, query executions, and processing of results is handled by Spring. This course will also help you discover named queries and how to add complexity to your query by substituting parameters that can be supplied when calling your methods. Once you are finished with this course, you'll have the skills to build efficient, robust, and easy-to-maintain applications by reducing the amount of boiler-plate code required.

Target

Prerequisites: none

Working with Spring Data JPA: Derived Query Methods

Course Number:
it_jpdjpadj_02_enus
Lesson Objectives

Working with Spring Data JPA: Derived Query Methods

  • discover the key concepts covered in this course
  • retrieve and read entities from a database table using a CrudRepository's findBy methods
  • recognize the exact syntax required to configure findBy methods in a CrudRepository
  • set up update and delete operations in a CrudRepository
  • implement derived query methods that operate on multiple parameters
  • identify the different ways to implement exact match lookups using derived query methods
  • search for entities based on patterns in a string property
  • search for entities based on ranges of values in numeric and date fields
  • summarize the key concepts covered in this course

Overview/Description
In this course, you'll learn more about configuring derived query methods in Spring Data JPA using the CrudRepository. Get hands-on experience using some of the methods of a CrudRepository, which are automatically implemented by the Spring Framework to retrieve entities from a database table and load them into Java objects. You will also examine how to configure new query methods, search for entities based on their properties, and implement create, read, update, and delete (CRUD) operations. After you are done with this course, you'll be able to efficiently work with persisted data in Spring Data JPA.

Target

Prerequisites: none

Working with Spring Data JPA: The Fundamentals of Spring Data JPA

Course Number:
it_jpdjpadj_01_enus
Lesson Objectives

Working with Spring Data JPA: The Fundamentals of Spring Data JPA

  • discover the key concepts covered in this course
  • outline the fundamentals of object-relational mappers and JPA
  • identify Spring framework projects and where Spring Data JPA fits in
  • create a project that uses Spring Data JPA, Hibernate, and a relational database
  • set up a class that represents an entity to be persisted into a database table using Spring Data JPA
  • define a DataSource and related beans in your application to enable data persistence using Spring Data JPA
  • configure a CrudRepository that enables basic CRUD operations on data
  • write the contents of Java objects into a database table
  • use Spring Boot and Spring Initializr to set up a project that adopts Spring Data JPA
  • load entity data from Java objects to a database table from a Spring Boot app
  • define a DataSource to be used in a java application within a properties file
  • summarize the key concepts covered in this course

Overview/Description
Spring Data JPA eases the development of applications that need to access Java Persistence API (JPA) by providing repository support. Use this course to get familiar with the basics of Spring Data JPA from a theoretical and practical standpoint. Through this course, you'll examine the concepts around Spring Data JPA and why this technology is a boon for developers, explore how to build a project that uses Spring Data JPA to connect to a database, and discover the use of the Spring Boot module. You'll also get a glimpse into the pieces which must come together to build an app that uses Spring Data JPA - data sources, a JPA implementation, and a CrudRepository. After finishing this course, you'll have the skills and knowledge to persist data using Spring Data JPA.

Target

Prerequisites: none

Close Chat Live